import Main from '@/components/mian.vue';

// 不作为Main组件的子页面展示的页面单独写，如下
export const otherRouter = {
    path: '/',
    name: 'otherRouter',
    redirect: '/home',
    component: Main,
    children: [
        { path: 'home', title: {i18n: 'home'}, name: 'home_index', component: () => import('@/components/home/home.vue') },
        { path: 'coincoin', name: 'coincoin', component: () => import('@/components/exchange/index.vue') },  //币币交易 
		
        { path: 'apply', name: 'apply', component: () => import('@/components/advertisement/apply.vue') },  //发布广告
        { path: 'buy', name: 'buy', component: () => import('@/components/advertisement/buy.vue') },  //发布广告  求购
        { path: 'sell', name: 'sell', component: () => import('@/components/advertisement/sell.vue') },  //发布广告 出售   
        
        
        
        { path: 'economicMan', name: 'economicMan', component: () => import('@/components/economicMan/economicMan.vue') },  //经济人
        { path: 'invite_friends', name: 'invite_friends', component: () => import('@/components/economicMan/invite_friends.vue') }, 

		
//		{ path: 'transfer', name: 'transfer', component: () => import('@/components/transfer/transfer.vue')},  //站内转账
        { path: 'MyAssets', name: 'MyAssets', component: () => import('@/components/MyAssets/ziChan.vue') },  //我的资产  
        { path: 'tiBit', name: 'tiBit', component: () => import('@/components/MyAssets/children/tiBit.vue') },  //提币   
        { path: 'chongBit', name: 'chongBit', component: () => import('@/components/MyAssets/children/chongBit.vue') },  //充币     
        { path: 'moneyRecord', name: 'moneyRecord', component: () => import('@/components/MyAssets/children/moneyRecord.vue') },  //提币
        { path: 'exchangeCoin', name: 'exchangeCoin', component: () => import('@/components/MyAssets/children/exchangeCoin.vue') },  //兑换
        { path: 'security', name: 'security', component: () => import('@/components/accountSecurity/security.vue'),
	        children:[
	        	{ path: 'alipay', name: 'alipay', component: () => import('@/components/accountSecurity/pay/alipay.vue') },  //修改支付宝支付方式
	        	{ path: 'backcard', name: 'backcard', component: () => import('@/components/accountSecurity/pay/back_card.vue') },  //修改修改银行卡支付方式
	       	 	{ path: 'wx', name: 'wx', component: () => import('@/components/accountSecurity/pay/wx.vue') },  //修改微信支付方式
	        ]
        },  //账号安全
        { path: 'isapply', name: 'isapply', component: () => import('@/components/broker/isApply.vue') },  //经纪人
        
        { path: 'changeemail', name: 'change_email', component: () => import('@/components/accountSecurity/children/change_email.vue') },  //绑定邮箱
        { path: 'changemobile', name: 'change_mobile', component: () => import('@/components/accountSecurity/children/change_mobile.vue') },  //修改绑定手机号
        { path: 'changeopwd', name: 'change_opwd', component: () => import('@/components/accountSecurity/children/change_opwd.vue') },  //修改登录密码
        { path: 'changetpwd', name: 'change_tpwd', component: () => import('@/components/accountSecurity/children/change_tpwd.vue') },  //修改资金密码
        { path: 'googleverify', name: 'google_verify', component: () => import('@/components/accountSecurity/children/google_verify.vue') },  //修改资金密码
        { path: 'transfer', name: 'transfer', component: () => import('@/components/accountSecurity/children/transfer.vue') },  //站内转账
       
        { path: 'authentication', name: 'authentication', component: () => import('@/components/authentication/identity.vue') },  //认证
        { path: 'senior', name: 'senior', component: () => import('@/components/authentication/children/senior.vue') },  //重新认证
        { path: 'realname', name: 'realname', component: () => import('@/components/authentication/children/real_name.vue') },  //认证
        { path: 'broker', name: 'broker', component: () => import('@/components/broker/isApply.vue') },  //经纪人申请
        { path: 'fundmannagement', name: 'fundmannagement', component: () => import('@/components/fundmanagement/fund.vue') },  //基金管理
        { path: 'Mentionmoneyaddress', name: 'Mentionmoneyaddress', component: () => import('@/components/Mentionmoneyaddress/moneyAddre.vue') },  //提币地址

        { path: 'frenchcurrency', name: 'frenchcurrency', component: () => import('@/components/frenchcurrency/frenchcurrency.vue') },  //法币交易   
        { path: 'frenchdetails', name: 'frenchdetails', component: () => import('@/components/frenchcurrency/frenchDetails.vue') },  //法币交易   
        { path: 'frenchOrder', name: 'frenchOrder', component: () => import('@/components/frenchcurrency/frenchOrder.vue') },  //法币交易   
        { path: 'zixunList', name: 'zixunList', component: () => import('@/components/notice/zixunList.vue') },  //公告   
        { path: 'zixunDetails', name: 'zixunDetails', component: () => import('@/components/notice/zixunDetails.vue') },  //公告  详情
        { path: 'fbOrder', name: 'fbOrder', component: () => import('@/components/order/fbOrder.vue') },  
        { path: 'ggOrder', name: 'ggOrder', component: () => import('@/components/order/ggOrder.vue') },
        { path: 'bbOrder', name: 'bbOrder', component: () => import('@/components/order/bbOrder.vue') },
        { path: 'agreement', name: 'agreement', component: () => import('@/components/notice/agreement.vue')},
        { path: 'crowdFunding', name: 'crowdFunding', component: () => import('@/components/crowdFunding/crowdFunding.vue')},//众筹
        { path: 'crowdFundRecord', name: 'crowdFundRecord', component: () => import('@/components/crowdFunding/crowdFundRecord.vue')},//众筹记录
    ]
};
export const loginpage = {  //登录
    path: '/login',
    name: 'login',
    meta: {
        title: '登录'
    },
    component: () => import('@/components/login.vue')
};
export const registerpage = {  //注册
    path: '/register',
    name: 'register',
    meta: {
        title: '注册'
    },
    component: () => import('@/components/register.vue')
};
export const forgetpwdpage = {  //忘记密码
    path: '/forgetpwd',
    name: 'forgetpwd',
    meta: {
        title: '忘记密码'
    },
    component: () => import('@/components/forget_pwd.vue')
};

export const adminset = {  //忘记密码
    path: '/adminset',
    name: 'adminset',
    meta: {
        title: '设置'
    },
    component: () => import('@/components/adminset.vue')
};

export const errorpage = {  //error
    path: '/error',
    name: 'error',
    meta: {
        title: '浏览器版本低'
    },
    component: () => import('@/components/error.vue')
};
// export const page404 = {
//     path: '/error', 
//     name: 'error',
//     meta: {
//         title: '浏览器版本过低'
//     }, 
//     component: () => import('@/components/error.vue')
// };

// export const page403 = {
//     path: '/403',
//     meta: {
//         title: '403-权限不足'
//     },
//     name: 'error-403',
//     component: () => import('@//views/error-page/403.vue')
// };

// export const page500 = {
//     path: '/500',
//     meta: {
//         title: '500-服务端错误'
//     },
//     name: 'error-500',
//     component: () => import('@/views/error-page/500.vue')
// };

// export const preview = {
//     path: '/preview',
//     name: 'preview',
//     component: () => import('@/views/form/article-publish/preview.vue')
// };
const routers = [
    otherRouter,
    loginpage,
    registerpage,
    forgetpwdpage,
    errorpage,
    adminset  //前台设置
];

// 所有上面定义的路由都要写在下面的routers里
export default  routers;
